package com.opencv.domain.po;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.alibaba.excel.metadata.BaseRowModel;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;

/**
 * @author qz.wu
 * @date 2021/11/19 17:05
 * @descriptions TODO
 */
public class UserExcelPO extends BaseRowModel {

    @ColumnWidth(20)
    @ExcelProperty(value = "用户ID", index = 0)
    private Long userId;

    @ColumnWidth(40)
    @ExcelProperty(value = "用户名称", index = 1)
    private String username;

    @ColumnWidth(10)
    @ExcelProperty(value = "年龄", index = 2)
    private Integer age;

    @ColumnWidth(80)
    @ExcelProperty(value = "地址", index = 3)
    private String address;

    @JsonFormat(pattern = "yyyy-MM-dd")
    @ColumnWidth(15)
    @ExcelProperty(value = "注册日期（天）", index = 4)
    private Date registerDate;


    public Date getRegisterDate() {
        return registerDate;
    }

    public void setRegisterDate(Date registerDate) {
        this.registerDate = registerDate;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public Integer getAge() {
        return age;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }
}
